home *** CD-ROM | disk | FTP | other *** search
- /* dir.h - portable directory routine definitions
- * :ts=8 ma=1 bk=0
- *
- * the "dir" struct is maintained by the opendir/readdir/closedir suite.
- * user code may read the contents, but should not modify them.
- *
- * FREELY DISTRIBUTABLE
- * j w hamilton, 7 nov 86
- */
-
- #ifndef LIBRARIES_DOS_H
- #include <libraries/dos.h> /* for FileInfoBlock */
- #endif /*LIBRARIES_DOS_H*/
-
- #ifndef LIBRARIES_DOSEXTENS_H
- #include <libraries/dosextens.h> /* for FileLock */
- #endif /*LIBRARIES_DOSEXTENS_H*/
-
- typedef struct dir { /* directory descriptor */
- struct FileLock *dd_lock; /* read lock on opened dir */
- struct FileInfoBlock *dd_fib; /* buffer for Examine/ExNext */
- } DIR;
-
- #define d_name dd_fib->fib_FileName
- #define d_namlen dd_fib->fib_Size
- DIR *opendir(/* char *dirname */);
- struct FileInfoBlock *readdir(/* DIR *dp */);
- long telldir(/* DIR *dp */);
- void seekdir(/* long pos */);
- void rewinddir(/* DIR *dp */);
- void closedir(/* DIR *dp */);
-